/*
 * ------------------------------------------------------------------
 * Copyright © 2017 Hangzhou DtDream Technology Co.,Lt d. All rights reserved.
 * ------------------------------------------------------------------
 *       Product:
 *   Module Name:
 *  Date Created: 2022/10/8
 *   Description:
 * ------------------------------------------------------------------
 * Modification History
 * DATE            Name           Description
 * ------------------------------------------------------------------
 * 2022/10/8    小谷 g2038          created
 * ------------------------------------------------------------------
 */
package com.gujh.java.jmx.karaf;

public enum BundleState {

    INSTALLED,
    RESOLVED,
    STARTING,
    ACTIVE,
    STOPPING,
    UNINSTALLED,
    ;

    public static BundleState convertState(String state) {
        for (BundleState bundleState : BundleState.values()) {
            if (bundleState.name().equalsIgnoreCase(state)) {
                return bundleState;
            }
        }
        return null;
    }
}
